<% this.title=list.title %>
  <% include header %>
    <div class="ui center aligned grid">
      <div class="row">
        <h1 class="ui header">
          <%= list.title %>
        </h1>
      </div>
      <div class="row" style="margin-top: -23px">
        <span class="ui label"> 上传者: <%= list.holder.username %> </span>
      </div>
      <div class="ui attached tabular menu top">
        <a class="item active" data-tab="introduction"> 简介 </a>
        <a class="item" data-tab="problems"> 题目 </a>
      </div>
      <div class="ui tab bottom attached segment active" data-tab="introduction">
        <%- list.introduction %>
      </div>
      <div class="ui tab bottom attached segment" data-tab="problems">
        <% let i=1 %>
          <table class="ui selectable celled table">
            <thead>
              <tr>
                <th> 状态 </th>
                <th> 题目 </th>
              </tr>
            </thead>
            <tbody>
              <% for (let problem of problems) { %>



                <tr>
                  <td>
                    <% if (problem.judge_state) { %>
                      <a href="<%= syzoj.utils.makeUrl(['submission', problem.judge_state.id]) %>">
                        <span class="status <%= problem.judge_state.status.toLowerCase().split(' ').join('_') %>">
                          <i class="<%= icon[problem.judge_state.status] || 'remove' %> icon"></i>
                        </span>
                      </a>
                    <% } %>
                  </td>
                  <td><a style="vertical-align: middle; " href="<%= syzoj.utils.makeUrl(['problem', problem.id]) %>"><%= problem.title %>
                    <% if (!problem.is_public) { %><span class="ui header"><span class="ui tiny red label">未公开</span></span><% } %>
                  </a></td>

                </tr>




                <% } %>
            </tbody>
          </table>
      </div>
    </div>
    <% include footer %>
      <script>
        $('.menu .item')
          .tab()
          ;
      </script>